#define _CRT_SECURE_NO_WARNINGS
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <assert.h>
int Rotate_Judge(char* arr1, char* arr2)
{
	int len1 = strlen(arr1);
	int len2 = strlen(arr2);
	if (len1 == len2)
	{
		strncat(arr1, arr1,len1);
		//若abcde，则abcdeabcde包含所有可能
		char* ret = strstr(arr1, arr2);
		if (ret == NULL)
			return 0;
		else
			return 1;
	}
	else
		return 0;
}
int main()
{
	char arr1[100] = { 0 };
	char arr2[50] = { 0 };
	printf("输入源字符串：");
	scanf("%s", arr1);
	printf("输入要判断的字符串：");
	scanf("%s", arr2);
	int ret = Rotate_Judge(arr1, arr2);
	if (ret)
	{
		printf("可以通过旋转得到");
	}
	else
		printf("无法通过旋转得到得到");
	return 0;
}